import {_decorator, Component, Node, Label} from 'cc';

const {ccclass, property} = _decorator;

@ccclass('Button')
export class Button extends Component {
    @property(Label)
    textLabel!: Label;

    start() {
        this.textLabel.string = '点击按钮'
    }

    update(deltaTime: number) {

    }

    onClickLeftButton() {
        this.textLabel.string = '点击了左边按钮'
    }

    onClickRightButton() {
        this.textLabel.string = '点击了右边按钮'
    }
}


